﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Windows.Forms;

using RemoteScriptingLibrary;
using RemoteScriptingLibrary.Microsoft.Win32;
using WindowsRemoteScripting.Action;

namespace WindowsRemoteScripting
{
    static class Program
    {
        /// <summary>
        /// The main entry point for the application.
        /// </summary>
//        private static HookWrapper w = new HookWrapper();

        [STAThread]
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            Form1._hookID = MacroRecorder.SetHook(MacroRecorder._proc);
            
            Application.Run(new Form1());
            //w.m_TextEventHandler += new HookWrapper.TextEventHandler(w_m_TextEventHandler);
            Win32.UnhookWindowsHookEx(Form1._hookID);
//            w.Dispose();
        }

        static void w_m_TextEventHandler(object sender, TextEventArgs e)
        {
            Form1.m_Form.Text = e.Text;
        }
    }
}
